﻿@model OAuthSignInModel
@{
    var client = ViewBag.client as OAuthApp.Data.App;
}

<div class="container-fluid">
    <div class="row">
        <div class="col-sm-12 col-md-4 offset-md-4 d-flex align-items-start justify-content-center"
             style="height: 100vh;">
            <div style="width:80%" class="mt-5">
                <div>
                    <img src="@client.Logo" width="68px" />
                </div>
                <div class="mx-2">
                    <h4 class="m-0">@client.Name</h4>
                    <p class="mt-1">@client.Website</p>
                </div>
                <hr />
                <form method="post" action="/OAuth/SignInPost">
                    <input name="scheme" type="hidden" value="@Model.scheme" />
                    <input name="client_id" type="hidden" value="@Model.client_id" />
                    <input name="scope" type="hidden" value="@Model.scope" />
                    <input name="nonce" type="hidden" value="@Model.nonce" />
                    <input name="state" type="hidden" value="@Model.state" />
                    <input name="grantType" type="hidden" value="@Model.grantType" />
                    <input name="redirect_uri" type="hidden" value="@Model.redirect_uri" />
                    <div class="mb-3">
                        <label class="form-label">账号</label>
                        <input name="userName" type="text" class="form-control" />
                    </div>
                    <div class="mb-3">
                        <label class="form-label">密码</label>
                        <input name="Pwd" type="password" class="form-control" />
                    </div>
                    <button type="submit" class="btn btn-primary">登录</button>
                    <a href="@Model.redirect_uri" class="btn btn-light mx-2">返回</a>
                </form>
            </div>
        </div>
    </div>
</div>